<!DOCTYPE html >
<html>
<head>
    <meta name="Generator" content="ECSHOP v2.7.3"/>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width">
    <title>新品上市</title>
    <link rel="icon" href="/template/pc1/images/wmh_favicon.ico" type="image/x-icon"/>
    <meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0, user-scalable=0"/>
    <link rel="stylesheet" type="text/css" href="/template/default/css/public.css"/>
    <link rel="stylesheet" type="text/css" href="/template/default/css/index.css"/>
    <link rel="stylesheet" type="text/css" href="https://static.9hive.cn/global/vendor/layui/css/layui.mobile.css"/>
    <script type="text/javascript" src="https://static.9hive.cn/global/vendor/jquery/jquery-2.1.4.min.js"></script>
    <script type="text/javascript" src="/template/default/js/jquery.json.js"></script>
    <script type="text/javascript" src="/template/default/js/transport.js"></script>
    <script type="text/javascript" src="/template/default/js/jquery.more.js"></script>
    <script type="text/javascript" src="/template/default/js/common.js"></script>
    <script src="https://static.9hive.cn/global/vendor/layui/layui.all.js"></script>
    <script type="text/javascript" src="https://static.9hive.cn/global/vendor/layer/layer.js"></script>

    <!--添加商品至购物车-->
    <script type="text/javascript" src="/template/default/js/product.js"></script>
    <script type="text/javascript" src="/res/js/jquery.metadata.js"></script>
    <style>

        body, div, a {
            font-family: HelveticaNeue !important;
            box-sizing: border-box;
        }

        body {
            background-color: #f8f8f8;
        }

        img {
            max-width: 100%;
        }

        .product-img {
            width: 100px;
            height: 100px;
            margin-right: 15px;
            margin-left: 3px;

        }

        .flex-horizontal {
            display: flex;
            width: 100%;
            align-items: center;
        }

        .flex-1 {
            flex: 1;
            min-height: 100px;
        }

        .flex-column-between {
            display: inline-flex;
            justify-content: space-between;
            flex-direction: column;
        }

        .justify-between {
            justify-content: space-between;
        }

        li {
            background-color: #fff;
            margin-bottom: 5px;
            padding: 5px 10px 5px 0;
        }

        .title {
            margin: 5px 0;
            font-family: STHeitiSC-Light;
            font-size: 18px;
            color: #333333;
            letter-spacing: 0;
            line-height: 18px;
            display: -webkit-box;
            overflow: hidden;
            text-overflow: ellipsis;
            word-wrap: break-word;
            word-break: break-all;
            white-space: normal !important;
            -webkit-line-clamp: 2;
            -webkit-box-orient: vertical;
        }

        .oldPrice {
            color: #E24615;
            font-size: 14px;
        }

        .buy-btn {
            border-radius: 5px;
        }

        .discount {
            color: #E24615;
            font-size: 16px;
        }

        .color-red {
            color: #E24615;
        }
    </style>

</head>

<body>
<ul>
    <%for(product in newProductList!){%>

    <li class="">
        <a class="flex-horizontal" href="/b/product/detailWap?id=${product.id}&shopId=${product.uid!}">
            <img class="product-img"
                 lay-src="<%if(isNotEmpty(product.backGroundImg)){%>${product.backGroundImg!}<%}else{%>${product.productImageList[0].sourceProductImagePath!}<%}%>"/>
            <div class="flex-1 flex-column-between">
                <div>
                    <div class="title">${product.name}</div>
                    <div><span class="oldPrice">￥${product.price}</span></div>
                </div>
                <div class="flex-horizontal justify-between">
                    <%if(product.productRebatePercentMoney!='' &&
                    product.productRebatePercentMoney!=0.00 &&
                    isNotEmpty(product.productRebatePercentMoney)){%>
                    <span class="color-red">返现￥<span class="discount">${product.productRebatePercentMoney}</span></span>
                    <%}else{%>
                    <span></span>
                    <%}%>
                    <span class="buy-btn">立即购买</span>
                </div>
            </div>
        </a>
    </li>
    <%}%>

</ul>

<script type="text/javascript" src="/template/default/js/weixxin.js"></script>

<script>
    (function () {
        layui.use('flow', function(){
            var flow = layui.flow;
            //当你执行这样一个方法时，即对页面中的全部带有lay-src的img元素开启了懒加载（当然你也可以指定相关img）
            flow.lazyimg();
        });
    })()
</script>
</body>
</html>